<script type="text/javascript">
	
function systemChange(target, radix) {
	let arr = [];
	do {
		arr.unshift(target%radix);
		target = Math.floor(target/radix);
	} while(target >= radix)
	arr.unshift(target%radix);
	return arr.join('');
}



/* 采用api方法 
	1. parseInt 			target是radix进制，parseInt将该进制的数转为十进制
	2. Number.toString()
*/ 
function systemChange1(target, radix) {
	// return parseInt(target, 8)
	return target.toString(16);
}
const res = systemChange1(255);
console.log(res);

</script>